package com.yulan.bankback.mapper.admin;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.yulan.bankback.entity.model.admin.MoneyFlow;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Component;

import java.util.List;

@Component
public interface MoneyFlowMapper extends BaseMapper<MoneyFlow> {

    @Select("select * from everyday_money_flow where time > NOW() - INTERVAL ${interval} " +
            " order by time ")
    List<MoneyFlow> getIntervalMoneyFlow(String interval);
}
